<!DOCTYPE html>
<html>
<head>
	<title>历史</title>
	<link rel="stylesheet" href="http://cdn.bootcss.com/bootstrap/3.3.0/css/bootstrap.min.css">
	<style type="text/css">
		body { margin: 20 auto 0 auto; }
	</style>
</head>
<body>
<?php
	$types = [
		1 => '小妖币',
		2 => '金币',
	];
?>
<div class="btn-group">
	<a href="/admin_1427a/logs" class="btn btn-default @if(old('type')=='') active @endif" role="button">所有</a>
	<a href="/admin_1427a/logs?type=charge" class="btn btn-default @if(old('type')=='charge') active @endif" role="button">充值</a>
	<a href="/admin_1427a/logs?type=change" class="btn btn-default @if(old('type')=='change') active @endif" role="button">提现</a>
	<a href="/admin_1427a/hldy" class="btn btn-default" role="button">欢乐钓鱼</a>
</div>
<table class="table table-bordered">
	<tr>
		<th>头像</th>
		<th>用户名</th>
		<th>业务</th>
		<th>说明</th>
		<th>类型</th>
		<th>数额</th>
		<th>时间</th>
	</tr>
	@foreach($logs as $log)
		<?php $user = $log->user; ?>
		<tr>
			<td>
				<a href="/admin_1427a/user?id={{ $user->id }}" ><img src="{{ $user->avatar }}" class="img-responsive" width="30" height="30" ></a>
			</td>
			<td><a href="/admin_1427a/user?id={{ $user->id }}" >{{ $user->nickname }}</a></td>
			<td>{{ $bussiness[$log->bussiness_id] }}</td>
			<td>{{ $log->desc }}</td>
			<td>{{ $types[$log->type] }}</td>
			<td>{{ $log->coin }}</td>
			<td>{{ $log->created_at }}</td>
		</tr>
	@endforeach
</table>
{{ $logs->appends($params)->links() }}
</body>
</html>